package com.changgou.Controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/test")
public class TestController {

    /***
     * 访问/test/hello  跳转到h页面
     * @param model
     * @return
     */
    @RequestMapping("/hello")
    public String hello(Model model){
        model.addAttribute("message","hello welcome!");
       model.addAttribute("a","color:blue");
        return "p";
    }
}